Jade.EmployeePage= Ext.extend(Ufida.Page, {
		create_widgets : function() {
			this.gridPanel = new Jade.EmployeeGridPanel();
			this.window = new Jade.EmployeeWindow();
			this.menu = new Ufida.widgets.Menu();
		},
		layout_widgets : function() {
			this.layout({
				'north' : this.menu,
				'center' : this.gridPanel
			});
			this.menu.change_menu_style('base');
		},

		bind_events : function() {
			this.gridPanel.on('add',this.window.showWindow);
			this.gridPanel.on('edit',this.window.showWindow );
			this.window.on('aftersave' ,function(){
				this.gridPanel.store.reload();
			}, this );
		},

		load_datas : function() {
			this.gridPanel.load();
		}
});

Ufida.render(Jade.EmployeePage);
